package pipeline;

import us.codecraft.webmagic.ResultItems;
import us.codecraft.webmagic.Task;
import us.codecraft.webmagic.pipeline.Pipeline;

import java.util.List;

/**
 * Created by zhangcheng on 2017/4/21 0021.
 */
public class KuaiIpPipeline implements Pipeline {
    public void process(ResultItems resultItems, Task task) {
        List<String> ips = resultItems.get("ip");
        List<String> ports = resultItems.get("port");
        for (int i = 0; i < ips.size(); i++) {
            System.out.println(ips.get(i) + ":" + ports.get(i));
        }
    }
}
